package com.abvnet.project.water.project.service;

import com.abvnet.common.utils.text.Convert;
import com.abvnet.project.water.project.domain.ProjectTech;
import com.abvnet.project.water.project.mapper.ProjectTechMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 污水工艺运行情况 服务层实现
 * 
 * @author duj
 * @date 2019-07-15
 */
@Service
public class ProjectTechServiceImpl implements IProjectTechService {
	@Autowired
	private ProjectTechMapper projectTechMapper;

	/**
     * 查询污水工艺运行情况信息
     * 
     * @param techId 污水工艺运行情况ID
     * @return 污水工艺运行情况信息
     */
    @Override
	public ProjectTech selectProjectTechById(Long techId) {
	    return projectTechMapper.selectProjectTechById(techId);
	}

    @Override
    public ProjectTech selectProjectTechByProjectId(Long projectId) {
        return projectTechMapper.selectProjectTechByProjectId(projectId);
    }

    /**
     * 查询污水工艺运行情况列表
     * 
     * @param projectTech 污水工艺运行情况信息
     * @return 污水工艺运行情况集合
     */
	@Override
	public List<ProjectTech> selectProjectTechList(ProjectTech projectTech) {
	    return projectTechMapper.selectProjectTechList(projectTech);
	}
	
    /**
     * 新增污水工艺运行情况
     * 
     * @param projectTech 污水工艺运行情况信息
     * @return 结果
     */
	@Override
	public int insertProjectTech(ProjectTech projectTech) {
	    return projectTechMapper.insertProjectTech(projectTech);
	}
	
	/**
     * 修改污水工艺运行情况
     * 
     * @param projectTech 污水工艺运行情况信息
     * @return 结果
     */
	@Override
	public int updateProjectTech(ProjectTech projectTech) {
	    return projectTechMapper.updateProjectTech(projectTech);
	}

	/**
     * 删除污水工艺运行情况对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
	@Override
	public int deleteProjectTechByIds(String ids) {
		return projectTechMapper.deleteProjectTechByIds(Convert.toStrArray(ids));
	}
	
}